package br.com.amigooo.deserializer;

import com.thoughtworks.xstream.XStream;

import br.com.amigooo.model.AccessRequest;
import br.com.amigooo.model.User;
import br.com.caelum.vraptor.deserialization.Deserializes;
import br.com.caelum.vraptor.deserialization.XStreamXMLDeserializer;
import br.com.caelum.vraptor.http.ParameterNameProvider;
import br.com.caelum.vraptor.ioc.Component;

public class CustomXStreamXMLDeserializer extends XStreamXMLDeserializer {  

    public CustomXStreamXMLDeserializer(ParameterNameProvider provider) {
		super(provider);
	}

	@Override  
    protected XStream getXStream() {  
         XStream stream = super.getXStream();  
         stream.processAnnotations(new Class[] {AccessRequest.class, User.class});
         return stream;  
    } 
}